﻿@model wychuan2.com.Areas.admin.Models.LiCai.LiCaiModel

<table class="table">
    <thead>
        <tr>
            <th>账户</th>
            <th>金额</th>
            <th>到期时间</th>
            <th>预期收益</th>
            <th>操作</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var detail in Model.LiCaiDetails.OrderBy(d=>d.ExpireDay))
        {
            <tr>
                <td>
                    <input type="hidden" name="Id" value="@detail.Id" />
                    @detail.Account<br /><small class="text-info"><i class="fa fa-clock-o"></i>@detail.BuyDay.ToString("yyyy-MM-dd")</small>
                </td>
                <td class="text-danger"><i class="fa fa-jpy"></i>@detail.Price</td>
                <td>@(detail.ExpireDay.HasValue?detail.ExpireDay.Value.ToString("yyyy-MM-dd"):"无期限")</td>
                <td><i class="fa fa-jpy"></i>@detail.ExpirePrice.ToString("0.00")<br /><small>年化收益:@detail.InterestRate%  </small><small><strong>@(detail.Times + "(" + detail.TimeUnit + ")")</strong></small></td>
                <td>
                    <a class="btn btn-white J_Edit">编辑</a>
                    <a class="btn btn-white J_Delete">删除</a>
                </td>
            </tr>
        }
        <tr>
            <td colspan="5">理财总金额：<small class="text-danger"><i class="fa fa-jpy"></i>@Model.LiCaiDetails.Sum(d => d.Price)</small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;预期总收益：<span class="text-danger"><i class="fa fa-jpy"></i>@Model.LiCaiDetails.Sum(d => d.ExpirePrice).ToString("0.00")</span></td>
        </tr>
    </tbody>
</table>
